Log in to ask questions, share your expertise, or stay connected to content you value. Don’t have a login? Learn how to become a member.
See matching posts in thread - reordering security policy's in different ......RE:...
To commit a configuration on occurrence of an event, the following configuration can be used: 1 [edit] 2 user@host # show event-options 3 policy <policy-name> ( 4 events <event-name>; 5 then ( 6 change-configuration ( 7 commands ( 8 "set system login message hello" ; 9 ) 10 ) 11 ) 12 ) 13 14 [edit] 15 user@host # As per the above configuration, when a specified event occurs in the system, this policy get executed and a configuration statement defined in policy will be committed. A user can specify more that one configuration statement in a single policy
Commit a Configuration Using an Event Policy To commit a configuration on occurrence of an event, you can use the following configuration: 1 [edit] 2 user@host# show event-options 3 policy <policy-name> ( 4 events <event-name>; 5 then ( 6 change-configuration ( 7 commands ( 8 "set system login message hello"; 9 ) 10 ) 11 ) 12 ) 13 14 [edit] 15 user@host# As shown in the configuration, when a specified event occurs in the system, the policy gets executed and a configuration statement defined in policy is committed. You can specify more that one configuration statement in a single policy
See matching posts in thread - #config #policy #RIP #vpn #based #routing #...
To raise an SNMP trap on occurrence of an event following configuration, use the following: 1 [edit] 2 user@host # show event-options 3 policy <policy-name> ( 4 events <event-name>; 5 then ( 6 raise- trap ; 7 ) 8 ) 9 10 [edit] 11 user@host # As per the above configuration, when a specified event occurs in the system, this policy is executed and an SNMP trap will be raised
To raise an SNMP trap on occurrence of an event following configuration, use the following: 1 [edit] 2 user@host# show event-options 3 policy <policy-name> ( 4 events <event-name>; 5 then ( 6 raise-trap; 7 ) 8 ) 9 10 [edit] 11 user@host# As per the above configuration, when a specified event occurs in the system, this policy is executed and an SNMP trap will be raised
Description The configuration text for each policy in the policy chain for the selected peer is extracted by the script and then displayed to the console in the correct sequential order
Execute CLI Commands Using an Event Policy To execute a CLI command on occurrence of an event, use the following configuration: 1 [edit] 2 user@host # show event-options 3 policy <policy-name> ( 4 events <event-name>; 5 then ( 6 execute-commands ( 7 commands ( 8 "show version" ; 9 ) 10 output-filename cmd output; 11 destination test dest; 12 ) 13 ) 14 ) 15 destinations ( 16 test dest ( 17 archive-sites ( 18 /var/tmp; 19 ) 20 ) 21 ) 22 23 [edit] 24 user@host # As per the above configuration, when a specified event occurs in the system, this policy is executed and a CLI command mentioned in the policy will execute (in this case "show version")
Execute CLI Commands Using an Event Policy To execute a CLI command on occurrence of an event, use the following configuration: 1 [edit] 2 user@host# show event-options 3 policy <policy-name> ( 4 events <event-name>; 5 then ( 6 execute-commands ( 7 commands ( 8 "show version"; 9 ) 10 output-filename cmd output; 11 destination test dest; 12 ) 13 ) 14 ) 15 destinations ( 16 test dest ( 17 archive-sites ( 18 /var/tmp; 19 ) 20 ) 21 ) 22 23 [edit] 24 user@host# As described in the previous configuration example, when a specified event occurs in the system, the policy is executed and a CLI command mentioned in the policy executes (in this example, "show version")